@import com.mgfireworks.mgplatform.mgadmin.sys.model.Advertisement
@extends("/form_template")
@args Boolean isEdit
@args Advertisement advertisement
@{
	if(advertisement==null){
		advertisement=new Advertisement();
	}
}
<div class="row form-horizontal form-label-left">
   <div class="col-md-12 col-sm-12 col-xs-12">
     <div class="x_panel">
       <div class="x_title">
         <h2>@if(isEdit){修改}else{添加}广告</h2>
         <div class="clearfix"></div>
       </div>
       <div class="x_content">
	       <div class="form-group">
	         <label class="control-label col-md-3 col-sm-3 col-xs-12" for="advId">广告编号<span class="required">*</span>
	         </label>
	         <div class="col-md-6 col-sm-6 col-xs-12">
	           <input type="text" id="advId" name="advId" value="@advertisement.getAdvId()" placeholder="请输入广告编号" required="required" @if(isEdit&&true){readonly="readonly"} class="form-control col-md-7 col-xs-12">
	         </div>
	       </div>
	       <div class="form-group">
	         <label class="control-label col-md-3 col-sm-3 col-xs-12" for="linkUrl">链接地址<span class="required">*</span>
	         </label>
	         <div class="col-md-6 col-sm-6 col-xs-12">
	           <input type="text" id="linkUrl" name="linkUrl" value="@advertisement.getLinkUrl()" placeholder="请输入链接地址" required="required" @if(isEdit&&false){readonly="readonly"} class="form-control col-md-7 col-xs-12">
	         </div>
	       </div>
	       <div class="form-group">
	         <label class="control-label col-md-3 col-sm-3 col-xs-12" for="advType">广告类型<span class="required">*</span>
	         </label>
	         <div class="col-md-6 col-sm-6 col-xs-12">
	           <input type="text" id="advType" name="advType" value="@advertisement.getAdvType()" placeholder="请输入广告类型" required="required" @if(isEdit&&false){readonly="readonly"} class="form-control col-md-7 col-xs-12">
	         </div>
	       </div>
	       <div class="form-group">
	         <label class="control-label col-md-3 col-sm-3 col-xs-12" for="advResource">广告资源<span class="required">*</span>
	         </label>
	         <div class="col-md-6 col-sm-6 col-xs-12">
	           <input type="text" id="advResource" name="advResource" value="@advertisement.getAdvResource()" placeholder="请输入广告资源" required="required" @if(isEdit&&false){readonly="readonly"} class="form-control col-md-7 col-xs-12">
	         </div>
	       </div>
	       <div class="form-group">
	         <label class="control-label col-md-3 col-sm-3 col-xs-12" for="areaId">播放地区
	         </label>
	         <div class="col-md-6 col-sm-6 col-xs-12">
	           <input type="text" id="areaId" name="areaId" value="@advertisement.getAreaId()" placeholder="请输入播放地区"  @if(isEdit&&false){readonly="readonly"} class="form-control col-md-7 col-xs-12">
	         </div>
	       </div>
	       <div class="form-group">
	         <label class="control-label col-md-3 col-sm-3 col-xs-12" for="online">是否上线<span class="required">*</span>
	         </label>
	         <div class="col-md-6 col-sm-6 col-xs-12">
	           <input type="text" id="online" name="online" value="@advertisement.getOnline()" placeholder="请输入是否上线" required="required" @if(isEdit&&false){readonly="readonly"} class="form-control col-md-7 col-xs-12">
	         </div>
	       </div>
	       <div class="form-group">
	         <label class="control-label col-md-3 col-sm-3 col-xs-12" for="addTime">添加时间
	         </label>
	         <div class="col-md-6 col-sm-6 col-xs-12">
	           <input type="text" id="addTime" name="addTime" value="@advertisement.getAddTime()" placeholder="请输入添加时间"  @if(isEdit&&false){readonly="readonly"} class="form-control col-md-7 col-xs-12">
	         </div>
	       </div>
			
			<ul id="js-form-error-list" class="form-error-list row alert alert-danger alert-dismissible fade in">
				@errors("<li class=\"col-sm-4 label\">{0}</li>")
			</ul>
       </div>
     </div>
   </div>
</div>